﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using System.Web;
using System.Web.Mvc;

namespace UtilitiesMvcUI.Infrastructure
{
    public class AddCultureToViewBagAttribute : ActionFilterAttribute
    {
        public override void OnActionExecuting(ActionExecutingContext filterContext)
        {

            filterContext.Controller.ViewBag.Culture = Thread.CurrentThread.CurrentCulture.Name;
        }
    }
}